/*
 * @Author: zouyanrong 466901787@qq.com
 * @Date: 2025-05-06 15:11:40
 * @LastEditors: ganjiejie 8025279+ganjiejie@user.noreply.gitee.com
 * @LastEditTime: 2025-05-14 15:34:22
 * @FilePath: \gj-vite-vue3-ts-pinia\src\router\index.js
 * @Description: 路由配置
 * 
 * Copyright (c) 2025 by ${git_name_email}, All Rights Reserved. 
 */
 import { createRouter, createWebHistory } from 'vue-router';

 const routes = [
  {
    path: '/',
    children: [
      {
        path: '/',
        name: 'Index',
        meta: {
          title: '首页',
          keepAlive: true,
          requireAuth: true
        },
        component: () => import('@/views/index.vue')
      },
      {
        path: '/tabbar',  // 修改路径为合法的路径
        name: 'Tabbar',   // 修改为唯一的 name
        meta: {
          title: 'tabbar切换',
          keepAlive: true,
          requireAuth: true
        },
        component: () => import('@/views/tab/index.vue')  
      }
    ]
  },
]

const router = createRouter({
  history: createWebHistory(),
  routes
});

export default router;